/*
	Designer: DaBai 
	E-mail: jamesbaicn@gmail.com
	License: MIT LICENSE

	Use BRT for UART, interrupt 4 include
*/
#ifndef __uart__
#define __uart__

extern bit startFlag;
extern bit finishedFlag;
extern unsigned char bitCount;
extern unsigned char receiveTmp[20];
void uart1_init(void);
void uart1_receive(void);
void uart1_send(unsigned char i);

void uart1_cmd(unsigned char t, unsigned int d, unsigned int d2,unsigned int d3);
void uart1_done(void);
void uart1_ready(void);
void uart1_error(void);

#endif